@import "../../variables.scss";

.color-picker-wrapper {
  position: relative;
  font-size: 16px;
}

.color-picker {
  display: flex;
  justify-content: space-around;
  align-items: center;
  padding: 8px 10px 8px 10px;
  border-radius: 3px;
  color: $white;
  transition: background 0.1s;
  cursor: pointer;
}

.color-picker:hover,
.color-picker:focus {
  background: $transparent-black;
}

.color-picker-menu {
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  width: 100px;
  margin-top: 4px;
  padding: 3px;
  border-radius: 3px;
  box-shadow: 0px 1px 3px rgba(0, 0, 0, 0.6);
  color: white;
  background: rgba(255, 255, 255, 0.9);
}

.color-picker-item {
  display: flex;
  justify-content: center;
  align-items: center;
  box-sizing: border-box;
  height: 40px;
  margin: 3px;
  cursor: pointer;

  &.blue {
    background: $blue;
    &:focus {
      background: $dark-blue;
    }
  }
  &.green {
    background: $green;
    &:focus {
      background: $dark-green;
    }
  }
  &.red {
    background: $red;
    &:focus {
      background: $dark-red;
    }
  }
  &.pink {
    background: $pink;
    &:focus {
      background: $dark-pink;
    }
  }
}
